/**
 * 
 */
package com.ihg.hiex.entity.session.meeting;

import org.apache.commons.lang3.StringUtils;

import com.demo2do.core.utils.Alias;

/**
 * @author downpour
 *
 */
@Alias("SessionMeetingType")
public enum Type {
    
    LARGE_GROUP("大组", "large"),
    
    SMALL_GROUP("小组", "small");

    private String description;
    
    private String alias;
    
    /**
     * 
     * @param description
     * @param alias
     * @param name
     */
    Type(String description, String alias) {
        this.description = description;
        this.alias = alias;
    }

    /**
     * 
     * @param alias
     * @return
     */
    public static Type aliasOf(String alias) {
        for(Type type : Type.values()) {
            if(StringUtils.equalsIgnoreCase(type.getAlias(), alias)) {
                return type;
            }
        }
        return null;
    }
    
    /**
     * @return the description
     */
    public String getDescription() {
        return this.description;
    }
    
    /**
     * 
     * @return
     */
    public String getAlias() {
        return alias;
    }
    
}
